import { IMessageBase } from "../../Framework/MQ/IMessageBase";
import { MessageManager } from "../../Framework/MQ/MessageManager";
import { SerializeStream } from "../../Framework/Serialize/SerializeStream";
import { SeqStringHelper } from "./SeqStringHelper";
import { EArenaMode } from "./EArenaMode";
type int = number;
//class SArenaMatch
    
    export  class SArenaMatch extends IMessageBase
    {
        constructor(arg1: Boolean=false)
        {
            
            super();if (arg1) 
            {
                MessageManager.instance().regist(this);
            }
            return;
        }

        public /* override */ getType(): int
        {
            return this._type;
        }

        public /* override */ clone(): IMessageBase
        {
            return new SArenaMatch();
        }

        public /* override */ __write(arg1: SerializeStream): void
        {
            arg1.writeInt(this.arenaId);
            this.mode.__write(arg1);
            arg1.writeInt(this.leftEnterTime);
            SeqStringHelper.write(arg1, this.enemys);
            return;
        }

        public /* override */ __read(arg1: SerializeStream): void
        {
            this.arenaId = arg1.readInt();
            this.mode = EArenaMode.__read(arg1);
            this.leftEnterTime = arg1.readInt();
            this.enemys = SeqStringHelper.read(arg1);
            return;
        }

        public /* const */_type: int=132;

        public /* var */arenaId: int;

        public /* var */mode: EArenaMode;

        public /* var */leftEnterTime: int;

        public /* var */enemys: Array<any>;

        public static /* var */_regist: SArenaMatch;
    }

            SArenaMatch._regist = new SArenaMatch(true);
        